package commandapplication;


// <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
// #[regen=yes,id=DCE.791FAD1F-75F2-FBA0-F41E-20D29A883569]
// </editor-fold> 
public class Invoker {

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.A1750174-2956-2044-B7B2-A1DD85A2801E]
    // </editor-fold> 
    private CommandAbstract command;

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.A903F316-5A5C-81E7-DD6B-FA55A90C7119]
    // </editor-fold> 
    public Invoker (CommandAbstract command) {
        this.command=command;
        
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,regenBody=yes,id=DCE.ECA18D2F-7B25-C13B-CFDA-E2F0AB4EB0E5]
    // </editor-fold> 
    public CommandAbstract getCommand () {
        return command;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,regenBody=yes,id=DCE.050C30A6-39FB-7867-470A-9BCD70447A54]
    // </editor-fold> 
    public void setCommand (CommandAbstract val) {
        this.command = val;
    }

    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.DAEBC84D-F32B-700F-7676-844496D93DD7]
    // </editor-fold> 
    public void invoke () {
        command.execute();
    }

}

